﻿using Legend.Component.Interface;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Content;

namespace Legend.Component.Common
{
    public class LinearMovement : Movement
    {
        private Vector3 velocity = Vector3.Zero;

        public Vector3 Velocity
        {
            get { return velocity; }
            set { velocity = value; }
        }

        public override void Update(GameTime gameTime, ContentManager contentManager)
        {
            Position += velocity * gameTime.ElapsedGameTime.Milliseconds / 1000;
        }
    }
}
